import itertools

string = "宁静致远厚积薄发"
combinations = list(itertools.permutations(string, 8))
count = len(combinations)

print(f"共有 {count} 种不同的汉字组合：")
for c in combinations:
    if len(set(c)) == 8:
        print("".join(c))
print(f"共有 {count} 种不同的汉字组合：")